package cn.tyoui.service.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import cn.tyoui.bean.UserBean;
import cn.tyoui.mapping.UserManageMapper;
import cn.tyoui.service.UserManageService;

@Service("userManageService")
public class UserManageServiceImpl implements UserManageService {

	@Resource
	private UserManageMapper userManageMapper;
	@Override
	public boolean addUser(UserBean user) throws Exception {
		return userManageMapper.addUser(user);
	}
	@Override
	public List<UserBean> queryAllUser() throws Exception {
		return userManageMapper.queryAllUsers();
	}
	@Override
	public List<UserBean> queryOneUser(UserBean user) throws Exception {
		return userManageMapper.queryOneUser(user);
	}
	@Override
	public void updateUser(UserBean user) throws Exception {
		userManageMapper.change(user);
	}
	@Override
	public void deleteUser(String id) throws Exception {
		userManageMapper.deleteUser(id);
	}

}
